﻿@model IEnumerable<EnetaMvc.ApplicationServices.Dto.HtmlControlDto>

@{
    ViewBag.Title = "Html Controls";
    Layout = "~/Views/Shared/_AdminLayout.cshtml";
}

<div class="content-txt">
    <div class="blog-head">
        <h2>Html Controls</h2>
    </div>
    <div class="content-info-area">
    <p>
        @Html.ActionLink("Create New", "Create")
    </p>
    <table style="width:100%;">
        <tr>
            <th style="text-align:left;width:90px;">
                Order Position
            </th>
            <th>
                Title
            </th>
            <th>
                Token
            </th>
            <th>
                Visible
            </th>
            <th></th>
        </tr>

    @foreach (var item in Model) {
        <tr>
            <td>
                @Html.DisplayFor(modelItem => item.OrderPosition)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Title)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Token)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Visible)
            </td>
            <td>
                @Html.ActionLink("Edit", "Edit", new { id=item.Id }) |
                @Html.ActionLink("Details", "Details", new { id=item.Id }) |
                @Html.ActionLink("Delete", "Delete", new { id=item.Id })
            </td>
        </tr>
    }

    </table>
        </div>
</div>